# docs/macros.py 宏处理示例
def define_env(env):
    @env.macro
    def api_link(page, anchor):
        # 在宏函数中添加调试输出
        print(f"Generated path: {page}, {anchor}")
        return f'file:///opt/.data/rbk/resources/scripts/site/api/{page}.html#{anchor}'
